import { getUserRouters } from "../api/index";
import { formatRouterTree } from "../utils/index";
export default {
  async setUserRouters({ commit, state }) {
    const userRouters = await getUserRouters(state.uid);
    const payLoad = formatRouterTree(userRouters);
    console.log(payLoad);
    commit("setUserRouters", payLoad);
    commit("setAuth", true);
  },
};
